<?php

class LogoutController extends Controller {

    /**
     * Logs out the current user and redirect to homepage.
     */
    public function actionIndex() {
        Yii::app()->user->logout(false);
        //$this->redirect('login');
        Yii::app()->controller->redirect(array('/admin/login'));
    }

}